package student.test;

import inheritance.Student;

// 注意，这里的 StudentTest2 类 并不是 Student 类的子类
public class StudentTest {
    public static void main(String[] args) {
        Student s = new Student();

        s.name = "张无忌";//public
        // s.number = 20201234; // protected : The field Student.number is not visible ( 既不同包也不是子类)
        // s.age = 18 ; // package-private : The field Student.age is not visible ( 不同包 )
        // s.head = "无忌的头" ; // private : The field Student.head is not visible ( 因为私有 )

        s.show();
    }
}
